package com.atguigu.gulimall.search.vo;

import lombok.Data;

import java.util.List;

/**
 * 返回给检索页面的所有信息
 */
@Data
public class EsSearchResult {

    //查询到的所有商品信息
    private List<?> products;
    //所有涉及的分类
    private List<?> catalogs;
    //所有涉及的品牌
    private List<?> brands;
    //所有涉及的属性
    private List<?> attrs;


    // ========= 分页信息 =========
    //当前页码
    private int pageNum;
    //总页码
    private int totalPages;
    //总记录数
    private long total;
    //导航页码
    private List<Integer> pageNavs;

    //面包屑导航数据
    private List<NavVO> navs;
    private List<Long> attrIds;

    @Data
    public static class NavVO{
        private String navName;
        private String navValue;
        private String link;
    }

    @Data
    public static class AttrVO {
        private Long attrId;
        private String attrName;
        private List<String> attrValue;
    }
    @Data
    public static class BrandVO {
        private Long brandId;
        private String brandName;
        private String brandImg;
    }
    @Data
    public static class CatalogVO {
        private Long catalogId;
        private String catalogName;
    }
}
